package com.shz.appletsapi.service;

import javax.mail.MessagingException;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import lombok.extern.slf4j.Slf4j;

@Slf4j
@Component
public class TaskService {

	@Autowired
	private EmailService emailService;
	
	
	@Scheduled(cron = "0 0 9 * * ?")
	//@Scheduled(cron = "0/5 * *  * * ? ")
	public void taskSend() throws MessagingException {
		emailService.Send();
	}
}
